package com.dc.excel.listener;


import com.alibaba.excel.context.AnalysisContext;
import com.alibaba.excel.event.AnalysisEventListener;
import com.dc.excel.model.MaterialMachineModel;

import java.util.ArrayList;
import java.util.List;

public class MaterialMachineListener extends AnalysisEventListener<MaterialMachineModel> {

    private List<MaterialMachineModel> results = new ArrayList<>();

    @Override
    public void invoke(MaterialMachineModel materialMachine, AnalysisContext analysisContext) {
        results.add(materialMachine);
    }

    @Override
    public void doAfterAllAnalysed(AnalysisContext analysisContext) {
    }

    public List<MaterialMachineModel> getResults() {
        return results;
    }
}
